package cn.kmsoft.spatialboot.common.object;

import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;

/**
 * @author
 * @date 2018/9/6
 */
public class StatsObject extends GeomObject {
    private String tableId;
    private String where;
    private List<String> groupFields;
    private List<StatsFieldObject> statsFields;
    private List<String> orderByFields;
    private HashMap<String, String> fieldMapping = new HashMap<String, String>();

    public void setTableId(String tableId) {
        this.tableId = tableId;
    }

    public String getTableId() {
        return tableId;
    }

    public void setWhere(String where) {
        this.where = where;
    }

    public String getWhere() {
        return where;
    }

    public void setFieldMapping(HashMap<String, String> fieleMapping) {
        this.fieldMapping = fieleMapping;
    }

    public HashMap<String, String> getFieldMapping() {
        return fieldMapping;
    }

    public List<StatsFieldObject> getStatsFields() {
        if (statsFields == null) {
            statsFields = new ArrayList<>();
        }
        return statsFields;
    }

    public void setStatsFields(List<StatsFieldObject> statsFields) {
        this.statsFields = statsFields;
    }

    public List<String> getOrderByFields() {
        if (orderByFields == null) {
            orderByFields = new ArrayList<>();
        }
        return orderByFields;
    }

    public void setOrderByFields(List<String> orderByFields) {
        this.orderByFields = orderByFields;
    }

    public List<String> getGroupFields() {
        if (groupFields == null) {
            groupFields = new ArrayList<>();
        }
        return groupFields;
    }

    public void setGroupFields(List<String> groupFields) {
        this.groupFields = groupFields;
    }
}
